home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 29
/
Volume 29 - JOGO DISK .iso
/
Games
/
jungle_adventure.swf
/
scripts
/
__Packages
/
SSMaterial.as
< prev
next >
Wrap
Text File
|
2006-11-29
|
3KB
|
93 lines
class SSMaterial
{
static var LOW_QUALITY = 0;
static var MEDIUM_QUALITY = 1;
static var HIGH_QUALITY = 2;
static var TEXTURES_ENABLED = true;
var initialized = false;
var surfaceTextureMode = 1;
var surfaceTexturePoint = 0;
var sideTextureMode = 1;
var sideTexturePoint = 4;
var sideTextureAlign = false;
var rearSurfaceLayer = 10;
var frontSurfaceLayer = 30;
var sideSurfaceLayer = 32;
var bottomSurfaceLayer = 29;
var sideTextureLayer = 31;
var layerShift = 0;
var ambientColor = 6710886;
var diffuseColor = 10066329;
var specularColor = 15658751;
var smoothing = 0;
var sideSmoothing = 0;
var smoothingQuality = SSMaterial.HIGH_QUALITY;
var capSurface = false;
var endAlign = 1;
var segmentLine = true;
var thickness = 10;
var frontDepth = 10;
var rearDepth = 10;
var sideExtrude = 0;
var bottomDepth = 0;
var friction = 0.9;
var traction = 0.5;
var bounciness = 0.1;
var emitDust = false;
var defaultType = "number";
var types = {impactSound:"string",ambientColor:"hex",diffuseColor:"hex",specularColor:"hex",surfaceTexture:"string",sideTexture:"string"};
function SSMaterial()
{
}
function prepare()
{
if(this.layerShift)
{
var _loc2_ = this.layerShift;
this.rearSurfaceLayer += _loc2_;
this.frontSurfaceLayer += _loc2_;
this.sideSurfaceLayer += _loc2_;
this.bottomSurfaceLayer += _loc2_;
this.sideTextureLayer += _loc2_;
}
if(this.frontDepth < 0)
{
this.frontDepth = 0;
}
if(this.rearDepth < 0)
{
this.rearDepth = 0;
}
if(this.thickness < 0)
{
this.thickness = 0;
}
if(this.bottomDepth < 0)
{
this.bottomDepth = 0;
}
this.ambientColor = new RGB(this.ambientColor);
this.diffuseColor = new RGB(this.diffuseColor);
this.specularColor = new RGB(this.specularColor);
switch(this.smoothingQuality)
{
case 0:
default:
this.ratios = [0,255];
this.alphas = [100,100];
break;
case 1:
this.ratios = [0,128,255];
this.alphas = [100,100,100];
break;
case 2:
this.ratios = [0,96,159,255];
this.alphas = [100,100,100,100];
}
}
function toString()
{
return "SSMaterial";
}
}